I'm looking to release an update to a Mac application. I've updated this app many times and had no issues. I haven't change any code signing related settings in the project.Now when I try to export a dev ID signed app in Organizer, I'm an error presented as a sheet:An error occurred during exportCodesign failedThe sheet has two buttons: Show Logs and & Cancel. I've filed a bug and sent the logs to Apple. If you cancel the sheet out and hit "Previous" Xcode wll crash on you.Anyone experience this and know of a solution? This is preventing me from pushing an update out to the folks.
Selecting any option will automatically load the page
Post
Replies
Boosts
Views
Activity
I have an NSTableView (view based). The cells (views) have a NSImageView to display a thumbnail.Thumbnails come from the web, and I load the thumbnails lazily. My class that handles the thumbnail loading has a delegate that sends back a message like this:-(void)thumbnailCache:(nonnull MyThumbnailCacheObject*)thumbnailCache
loaddedThumbnailsForURLs:(nonnull NSArray<NSURL*>*)imageURLs
{
//Get the row indexes for the urls...and then call....reloadDataForRowIndexes:columnIndexes
//table view doesnt have columns.
[self.tableView reloadDataForRowIndexes:indexes columnIndexes:[NSIndexSet indexSetWithIndex:0]];
}However the cells don't update. At first I thought it was a bug in my thumbnail loading, but a call to reloadData does update the cells properly.Wrapping the reloadDataForRowIndexes:columnIndexes: in between beginUpdates and endUpdates calls makes no difference.Does reloadDataForRowIndexes:columnIndexes: not work with view based table views? I'm tempted to just use reloadData and hope everything works out okay.
I can no longer run my app from Xcode with code signing for my Mac app. I've configured a debug provisioning profile manually and tried that but it fails, saying the embedded framework is not code signed at all.I tried "Automatic" code signing but it fails with the same error:code object is not signed at allIn subcomponent: PATH_HERECommand /usr/bin/codesign failed with exit code 1The only way I'm able to get the app to run is to turn off code signing alltogether in Debug mode. I've noticed in that case though, testing is pretty useless because my app can't event write a security scoped bookmark to disk.
Topic:
Code Signing
SubTopic:
Certificates, Identifiers & Profiles
Tags:
Signing Certificates
Provisioning Profiles
Simple UIActivityViewController configured like this:NSArray *activityItems = @[linkURL]; //<--linkURL is an NSURL.
UIActivityViewController *activityViewController = [[UIActivityViewController alloc]initWithActivityItems:activityItems
applicationActivities:nil];Then I present it:[self presentViewController:activityViewController animated:YES completion:nil];If I select the Mail or Messages activity the activity works as expected. But if I select the "Reminders" or "Notes" activity the view controller for those activities present briefly before automatically dismissing and logging out:: SLRemoteComposeViewController: (this may be harmless) viewServiceDidTerminateWithError: Error Domain=_UIViewServiceInterfaceErrorDomain Code=3 "(null)" UserInfo={Message=Service Connection Interrupted}Anyone know the potential cause / workaround? The completionWithItemsHandler block does not return me an error.
I'm having a hard time tracking the cause of this/ coming up with a workaround for this potential bug in UITableView. I have a UITableView, using the default section header view (I implement -tableView:titleForHeaderInSection: and return a string).After deleting some rows using -deleteRowsAtIndexPaths:withRowAnimation: I notice sometimes an extra header view will appear inside my UITableVIew. It has the same title as the sticky header above it, but it appears the table view lost its reference to the header view but didn't clean it up from the view hierarchy (it scrolls with the table view, never sticks to the top anymore). If I manually empty the entire data source and call reload data on the table view, the abandoned header view is still visible. Has anyone run into this before and know of possible cause and/or workaround?
So to support Apple Silicon in my app I need a fat version OpenSSL for Intel/Arm.
However, I cannot get OpenSSL to build for ARM if I lower the deployment target to an earlier version of macOS before Big Sur.
I was able to make a fat version of OpenSSL by making the ARM half have a deployment target of 10.15, but when added to my project, Xcode spits out warnings about Object files built for a newer macOS version than being linked.
Anyone know the proper procedure to make a backward compatible version (pre-macOS 10.15) of OpenSSL static library and still support M1 natively?
I don't think I'm currently willing to raise the deployment target of my app to 10.15 just to link the OpenSSL library.
So my app creates user notifications. Sometimes when I tap one of these notification to open the app, it crashes. It happens seemingly randomly and is not easy to reproduce. My app's UNUserNotificationCenterDelegate does something like this (shortened to keep the post concise):
-(void)userNotificationCenter:(UNUserNotificationCenter*)center
didReceiveNotificationResponse:(UNNotificationResponse*)response
withCompletionHandler:(void(^)(void))completionHandler
{
if (![response.actionIdentifier isEqualToString:UNNotificationDefaultActionIdentifier])
{
//only care about the default action...return out otherwise.
completionHandler();
return;
}
completionHandler();
UNNotificationRequest *request = response.notification.request;
NSString *requestIdentifier = request.identifier;
if (requestIdentifier == nil)
{
return;
}
[database selectModelFromId:requestIdentifier withCompletionHandler:^(MyModel *modelObj,
NSError *errorOrNil)
{
if (modelObj != nil)
{
[self makeWebViewControllerForModeAndPutOnScreen:modelObj];
}
else
{
NSLog(@"error loading data for notification...");
}
}];
}
Okay so the view controller loaded uses WKWebView to load web content. Again every once in awhile the app crashes when I tap a notification. No crash report is ever generated for my app. I don't know why this is happening. Anybody experience anything similar and know what the issue could be? Thanks in advance.
I'm unable to test Subscription renewal via StoreKit Testing in Xcode unless the subscription is a monthly subscription. I'm trying to test a weekly subscription but under the Editor menu there is no entires for anything other than Monthly? (Xcode 13.3). Setting the interval to the fastest ("Monthly Renewal Every 30 Seconds") does nothing if the active subscription is a weekly subscription. Is there no way to test subscriptions unless they are monthly?
I'm currently using a StoreKit configuration file to test auto renewable subscriptions. On my device I am subscribed to subscription with a duration set to weekly. The subscription renewal rate is set to "Monthly Renewal Every 15 Minutes."
This all works fine for awhile. The subscription auto renews. But after a few hours suddenly my app detects that the subscription has expired and the app UI behaves accordingly.
My app does the following:
Looks at the in app purchase receipts and finds the one with the latest expiration date.
If the current date is later than the expiration date of this receipt my app acts like the subscription has expired. I even add a bit of extra time on the expiration date in case an auto renewable transaction gets held up (in the debug environment I add a couple hours).
I don't take any interaction to cancel the subscription in the "Manage StoreKit Transactions" area of Xcode, nor do I do anything programmatically to cancel the subscription. Autorenew just stops working.
I noticed this happens when the in app purchase receipt count is high (currently it is at 1776 in app purchase receipts). So I'm wondering if this is a bug in the StoreKit configuration environment that happens when auto renewing subscriptions causes the in app purchase receipts to grow large and it just quits auto renewing the subscription?
If I navigate to the area in my user interface and resubscribe to the weekly plan it works again for awhile. The issue then will reoccur after a few hours again, forcing me to "resubscribe" to the plan I've never unsubscribed for.
Is StoreKit testing discarding in app purchase receipts when the receipt gets large but instead of discarding the oldest receipt it removes the in app purchase receipt that is not yet expired, thus forcing me to resubscribe?
Anyone else experience this issue with StoreKit testing? Seems like it's an issue with the testing environment but naturally can't be sure.
Topic:
App & System Services
SubTopic:
StoreKit
Tags:
Subscriptions
StoreKit
StoreKit Test
App Store Receipts
I'm working on an app that uses Auto renewable subscriptions. The app uses StoreKit (not StoreKit2). It is pre-release.
I was under the assumption that if the user subscribes via in app purchase on Device 1, and then installs the same app on Device 2 (logged in with the same Apple ID) that the receipt on Device 2 would include the in app purchase receipt on initial install, and therefore by inspecting the receipt locally I could determine that showing onboarding UI on Device 2 is not necessary (and all this could be done locally). Is this not true? I just watched the WWDC 2022 session 110404 "Implement proactive in-app purchase restore" which seems to indicate that this is not the case?
I'd like to test how my app behaves when the user signs out of iCloud and my app is in memory. In the iOS Simulator, the "Sign Out" button for iCloud is grayed out so I can't use the simulator to test. I'm hesitant to use a real device tied to my Apple ID because signing out of iCloud System wide has side effects with many apps and I don't want to potentially lose any data.
However, I did test on a real device by going the Settings app -> iCloud and disabled iCloud only for my app. When I do this, the system terminates my app and does not post a CKAccountChangedNotification.
I only tested turning off the iCloud switch for my app. Does the system simply terminate apps when the user logs out of iCloud system wide too? In what cases is the CKAccountChangedNotification posted? Detecting sign out by listening for CKAccountChangedNotification would seem to be pointless if apps are terminated when the user signs out of iCloud.
I'm getting some Crash Reports for an app of mine that's on the Mac App Store. A few details:
-All the crash reports are on ARM-64 Macs.
-The call stack shows my app calling NSURL's -getResourceValue:forKey: method with NSURLLocalizedNameKey, which is the last call made by my app before the crash. After that crash logs look like this:
**Thread 0 Crashed:
0 libobjc.A.dylib 0x00000001a623c4b0 objc_retain + 16
1 LaunchServices 0x00000001a6954f68 -[FSNode(PathAndName) nameWithError:] + 72
2 LaunchServices 0x00000001a6a36278 +[_LSDisplayNameConstructor(ConstructForAnyFile) displayNameConstructorWithContextIfNeeded:bundle:bundleClass:node:preferredLocalizations:error:] + 2732
3 LaunchServices 0x00000001a6a357ac +[_LSDisplayNameConstructor(ConstructForAnyFile) displayNameConstructorWithContextIfNeeded:node:error:] + 44
4 LaunchServices 0x00000001a6ae5b20 LaunchServices::URLPropertyProvider::getDisplayNameConstructor(LaunchServices::Database::Context&, FSNode*, LaunchServices::URLPropertyProvider::State*, NSError* __autoreleasing*) + 88
5 LaunchServices 0x00000001a6ae1930 LaunchServices::URLPropertyProvider::prepareLocalizedNameValue(LaunchServices::Database::Context&, FSNode*, __FileCache*, __CFString const*, LaunchServices::URLPropertyProvider::State*, NSError* __autoreleasing*) + 328
6 LaunchServices 0x00000001a6953d6c LaunchServices::URLPropertyProvider::prepareValues(__CFURL const*, __FileCache*, __CFString const* const*, void const**, long, void const*, __CFError**) + 456
7 CoreServicesInternal 0x00000001a8def6f0 prepareValuesForBitmap(__CFURL const*, __FileCache*, _FilePropertyBitmap*, __CFError**) + 452
8 CoreServicesInternal 0x00000001a8dec5ec _FSURLCopyResourcePropertyForKeyInternal(__CFURL const*, __CFString const*, void*, void*, __CFError**, unsigned char) + 236
9 CoreFoundation 0x00000001a64546b0 CFURLCopyResourcePropertyForKey + 144
10 CoreFoundation 0x00000001a646b944 -[NSURL getResourceValue:forKey:error:] + 120**
--
I haven't been able to reproduce the issue on my ARM-64 Mac. Not sure what's going with _LSDisplayNameConstructor or if there is a way I can workaround/resolve.
Some of the crashes have the following lines included:
Kernel Triage:
VM - Compressor failed a blocking pager_get
VM - Compressor failed a blocking pager_get
VM - Compressor failed a blocking pager_get
VM - Compressor failed a blocking pager_get
VM - Compressor failed a blocking pager_get
I have an iOS app that was rejected and I submitted a revised binary. In my case auto-renewable subscriptions were returned with the initial rejections and I didn't realize I had to add them for review again with my revised submission....so I submitted a revised binary which got rejected because the subscriptions were returned on the initial rejection.
So I go to "Subscriptions" area for my app and the status is "Developer Action Needed." If I click a subscription the "Submit for Review" button is disabled. I tried making an edit to the Subscription to see if that would cause the button to become enabled but it does not. Can't figure out how I can resubmit these subscriptions for review....so my submission is stuck...
Perhaps when an app with attached iAP/Subscriptions is rejected they shouldn't detach iAP/subscriptions from the app? Developers can easily not notice and submit a new build and not realize that their iAP/subscriptions are no longer attached to the build...and if App Review doesn't notice you could have an app get on the Store which potentially shows UI for non-working iAP/subscriptions.
If anyone has ran into this and could help I'd appreciate it. Thanks a lot.
Topic:
App Store Distribution & Marketing
SubTopic:
App Store Connect
Tags:
App Store Connect
StoreKit
I'm trying to figure out how I'm suppose to work with this API on UIFindSession:
- (void)performSearchWithQuery:(NSString *)query options:(nullable UITextSearchOptions *)options;
I want to provide a UITextSearchOptions object, but the properties are readonly so I'm not sure what purpose it serves exposing it in the public API?
@interface UITextSearchOptions : NSObject
/// See UITextSearchMatchMethod above.
@property (nonatomic, readonly) UITextSearchMatchMethod wordMatchMethod;
/// Comparison options to use when searching for strings.
@property (nonatomic, readonly) NSStringCompareOptions stringCompareOptions;
@end
So I can't simply invoke a search like this...which would've really been nice...
UIFindSession *session = findInterfaction.activeFindSession;
UITextSearchOptions *searchOptions = [[UITextSearchOptions alloc]init];
searchOptions.stringCompareOptions = NSCaseInsensitiveSearch; //readonly can't...
[session performSearchWithQuery:searchString options:searchOptions];
There is this API:
/// available in @c UITextSearchOptions, which can be either modified, augmented, or omitted.
@property (nonatomic, readwrite, copy, nullable) UIMenu *_Nullable (^optionsMenuProvider)(NSArray<UIMenuElement *> *defaultOptions);
So I can remove menu items that edit the UITextSearchOptions but how exactly do I "override" them for my needs?
I'd like to resize a UITargetedPreview as part of a custom animation.
I tried doing this by using the animator provided in:
- (void)tableView:(UITableView *)tableView willDisplayContextMenuWithConfiguration:(UIContextMenuConfiguration *)configuration animator:(nullable id<UIContextMenuInteractionCommitAnimating>)animator
But resizing the source view for the target preview does not cause the container view to resize with it (leaving a large gap after my custom animation completes). So my preview is wrapped in a visual effects view that doesn't downsize with UITargetedPreview's view I provided.
I also tried wrapping a snapshot view in a UIViewController and using previewProvider block instead of using a UITargetPreview.
I am able to resize the previewViewController by setting the preferredContentSize property and resizing works, but it still doesn't look right because the default animation for the preview view controller breaks with the custom animation I'm trying to implement.
Anyone know if this is possible?